home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / archival / genindex / draft-index-format < prev    next >
Encoding:
INI File  |  1992-08-27  |  4.4 KB  |  175 lines

  1. [as discussed in de-mirror up to Aug 07, 1992]
  2. [editorial changes / bug fixes by {cross,marion}@cs.tu-berlin.de Aug 15, 1992]
  3. [info-line extensions by {heiko,vera,cross}@{cs.t,f}u-berlin.de Aug 22, 1992]
  4. [info-line extensions frozen Aug 28, 1992]
  5.  
  6.         DRAFT Syntax for FTP server index files
  7.         ---------------------------------------
  8.  
  9.  
  10.     index        = *( line CRLF )
  11.  
  12.     line        = comment-line
  13.             / info-line
  14.             / index-line
  15.  
  16.     comment-line    = "#" white-space text
  17.                     -- user information, format undefined
  18.  
  19.     info-line        = "#" 1*<any CHAR, excluding white-space and CRLF>
  20.               white-space text
  21.                     -- reserved for further parsable
  22.                        information (contact addresses,
  23.                        IP addresses...)
  24.                        (preliminary standard see below)
  25.  
  26.     index-line        = directory-line
  27.             / symlink-line
  28.             / file-line
  29.  
  30.     directory-line    = ("D" / "d") 
  31.                 ("R" / "r" / "-")
  32.                 ("W" / "w" / "-")
  33.                 ("X" / "x")
  34.                 white-space
  35.                 date-time white-space
  36.                 "0" " "
  37.                 pathname
  38.                     -- directories always have size 0. 
  39.                           the search permission 'x' must
  40.                        be set.
  41.  
  42.     file-line        = ("F" / "f")
  43.                 ("R" / "r") 
  44.                 ("W" / "w" / "-")
  45.                 ("X" / "x" / "-")
  46.                 white-space
  47.                 date-time white-space
  48.                 size " "
  49.                 pathname
  50.                     -- files must be readable.
  51.                        There is NO white-space between
  52.                        size and pathname to support
  53.                        pathnames with leading 
  54.                        white-space.
  55.  
  56.     symlink-line     = ("L" / "l")
  57.                 "---"
  58.                 white-space
  59.                 date-time white-space
  60.                 "0" " "
  61.                 pathname 
  62.                 " " "-" ">" " "
  63.                 pathname
  64.                     -- symlinks have size 0 and
  65.                        mode '---' by convention.
  66.                        There is NO white-space
  67.                        between the two pathnames
  68.                        in order to support pathnames
  69.                        containing white-space.
  70.  
  71.     date-time        = date " " time
  72.  
  73.     date        = day "-" month-name "-" year
  74.  
  75.     time        = hour ":" minute
  76.                     -- time should be given in GMT
  77.  
  78.     day            = ("0" / "1" / "2" / "3") 
  79.               DIGIT
  80.                     -- days < 10 have a leading 0.
  81.  
  82.     month-name        = ("Jan" / "Feb" / "Mar" / "Apr" / "May" /
  83.                "Jun" / "Jul" / "Aug" / "Sep" / "Oct" /
  84.                "Nov" / "Dec")
  85.  
  86.     year        = 4*DIGIT
  87.                     -- year should be >= 1970.
  88.  
  89.     hour        = 2*DIGIT
  90.                     -- in 24 hour notation; entries
  91.                        < 10 have leading zeros
  92.  
  93.     minute        = 2*DIGIT    -- entries < 10 with leading
  94.                        zeros
  95.  
  96.     size        = ( <any DIGIT except "0">  *( DIGIT ) )
  97.             / "0"
  98.  
  99.     pathname        = <any text not containing CRLF or " -> ">
  100.                     -- path components should be
  101.                        divided by "/" (UNIX
  102.                        pathname convention).
  103.  
  104.     text        = *( CHAR )
  105.     
  106.     white-space        = *( <ASCII SPACE> / <ASCII TAB>)
  107.  
  108.     token        = <text without white-space>
  109.  
  110.     CHAR        = <any ISO-8859-1 (8-bit ISO10646 subset) character>
  111.                     -- in POSIX.1, file names may
  112.                        contain any printable
  113.                        8-bit-character (at least,
  114.                        I think so ;-)).
  115.  
  116.     NUMBER        = DIGIT *( DIGIT )
  117.  
  118.     DIGIT        = <any ASCII digit "0" .. "9">
  119.  
  120.  
  121.  
  122.         valid Info Line keywords && formats (preliminary)
  123.         -------------------------------------------------
  124.           ( M = multiple lines allowed, ! = mandatory ) 
  125.  
  126.  !M server-name        = "#NAME" white-space token
  127.                     -- any CNAME, first occurrence
  128.                        is preferred
  129.  
  130.   M contact-address    = "#MAIL" white-space *( token )
  131.                     -- RFC822 mail addresses
  132.  
  133.  !  index-version    = "#VERSION" white-space NUMBER "." NUMBER
  134.                     -- INDEX format version. MANDATORY.
  135.                        Indices without a #VERSION-line
  136.                        are illegal.
  137.  
  138.  !  create-date        = "#CREATED" white-space date-time
  139.                     -- index creation time, same timezone
  140.                        and format as other INDEX dates.
  141.                        Mandatory because it is used for
  142.                        diffs.
  143.  
  144.     timezone        = ( "+" / "-" ) <four digits>
  145.               white-space text
  146.                     -- offset to GMT as in RFC822
  147.                        text is optional and describes 
  148.                        the timezone (not parsed)
  149.  
  150.     index-timezone    = "#INDEX-TIMEZONE" white-space timezone 
  151.                     -- timezone of INDEX dates,
  152.                        always +0000
  153.  
  154.     server-timezone    = "#SERVER-TIMEZONE" white-space timezone
  155.                     -- server's home timezone
  156.  
  157.     organization    = "#ORGANIZATION" white-space text
  158.                     -- name of server's organization;
  159.                        not parsed
  160.  
  161.     location        = "#LOCATION" white-space text
  162.                     -- server coordinates etc. (not spec)
  163.  
  164.     access        = "#ACCESS" white-space text
  165.                     -- access restrictions, not parsed.
  166.  
  167.     sort-field        = "date" / "path" / "filename"
  168.  
  169.     sort-specifier    = [ "casesensitive" white-space]
  170.               [ "reverse" white-space]
  171.               sort-field
  172.  
  173.     sort        = "#SORT" sort-specifier
  174.                     -- no sort line means unsorted
  175.